1. Field of Invention
The present invention relates generally to developing web applications such as applications for the World Wide Web. More particularly, the present invention relates to a system which allows a number of tables and a number of rows of data which may have dynamic properties in each table to be determined dynamically and displayed.
2. Description of the Related Art
Software developers often develop web applications, e.g., applications associated with the World Wide Web, that provide user interfaces that allow users to efficiently access information and data. Tables are often used as user interface components to represent data derived from contents of a view instance in a tabular form. The presentation of data in tabular form allows a user to readily organize the data, as for example by sorting columns in a table.
Typically, a fixed, or static, set of tables is presented in user interface windows. When a user enters input into a user interface window, the input is used to identify at least one table that is to be displayed. In a web application, input data generally has a particular set of tables associated therewith. While the input types designate the set of tables and which tables to display, as well as the names of the tables and the columns of the tables, the inputs themselves identify the number of rows that are included in the tables.
With reference to FIG. 1A, a standard table that may be displayed in a window that displays a user interface page associated with a web application will be described. A user interface page 102 includes an area 108 into which a user input may be entered. Depending upon the type of input entered into area 108, at least one appropriate table 106 will be displayed. Table 106 is typically specified as including a particular number of columns 110, 114, while a number of rows 118a-g may vary depending upon the amount of information that is to be displayed in table 106. That is, the number of rows 118a-g is dynamic. The particular number of columns 110, 114 is specific to table 106, i.e., is substantially static with respect to table 106.
The number of tables included in a user interface page associated with a web application may vary depending upon requirements of a particular input. By way of example, for a web application associated with a bank transaction, the input may be a customer login. The web application may, when any customer login is detected, display a fixed or otherwise static number of tables. The tables may each have any number of rows that are specific to the particular customer login that is inputted.
FIG. 1B is a diagrammatic representation of a user interface page of a web application which displays a plurality of tables. A user interface page 122 includes an input area 128 that is arranged to accept an input, as for example a customer login. Tables 136a, 136b are displayed after the input is entered. As shown, an input entered into input area 128 causes tables 136a, 136b which each include two columns to be displayed. Table 136a includes columns 130, 134, while table 136b includes columns 140, 144.
The input into input area 128 is such that table 136a includes five rows 138a-e, while table 136b includes two rows 148a, 148b. Hence, the input has data or information associated with both tables 136a, 136b, as indicated by each table 136a, 136b including at least one row. By way of example, if the input into input area 128 is a customer login for a bank transaction, table 136a may be arranged to display savings account numbers associated with the customer login in column 130 and corresponding balances in column 134. Similarly, table 136b may be arranged to display checking account numbers associated with the customer login in column 140 and corresponding balances in column 144.
Typically, the type of input into input area 128 determines the number of tables 136a, 136b that are displayed, whereas the actual input into input area 128 determines the number of rows 138a-e in table 136a, and the number of rows 148a, 148b in table 136b. That is, an input type specifies the number and names of tables displayed, while information associated with the input specifies the number of rows in each table. Returning to the bank transaction example, even if a customer identified by a customer login does not have at least one associated checking account, a table that is associated with checking accounts is displayed, though the table would have no rows included for data. A table for savings accounts and a table for checking accounts are generally shown for each customer login input as a web application is created to specify that an input type that is a customer login causes both tables to be displayed.
FIG. 1C is a diagrammatic representation of a user interface page of the same web application as associated with user interface page 122 of FIG. 1B, as shown with a substantially empty table. A user interface page 162 is arranged to accept an input into an input area 168. Once the input is accepted, tables 176a, 176b are displayed. If the input is a customer login for a bank transaction, for example, table 176a may display a column 170 for savings account numbers and a column 174 for associated balances, while table 176b may display a column 180 for checking account numbers and a column 184 for associated balances. As the customer login is associated with a plurality of savings accounts, rows 138a-e are displayed as a part of table 176a. As shown, the customer login is not associated with any checking accounts. However, a substantially empty table 176b that is arranged to contain information relating to checking accounts associated with the customer login is shown.
The steps associated with displaying tables in a user interface page of a web application will be described with reference to FIG. 2. A process 200 of displaying tables in a user interface page of a web application begins at step 204 in which input is provided through a user interface of a window or page, e.g., a web page. The input, which may be input into an input area of a user interface page such as input area 108 of FIG. 1A, is parsed or otherwise examined by the web application upon entry. A fixed set of tables, or a fixed number of tables, is generated in step 206 based upon the type of input that was provided. Some types of input may be associated with a single table, while other types of input may be associated with more than a single table. It should be appreciated that while the number of tables that are displayed is fixed for each type of input, the number of rows in each table is dependent, at least in part, upon information provided in the input.
After generating a fixed set of tables, the tables are populated appropriately in step 208. By way of example, for each table that is generated, when the input has associated data to display in the table, the table is effectively populated with that data. If the input does not have data that pertains to a particular table, though the table is generated, the table is not populated with any data associated with the input. Then, in step 210, the fixed set of tables is displayed for the type of input that has been provided. Each table is displayed with rows which contain data associated with the input that corresponds to the intended content of the table. Hence, a table may be displayed with no rows of data in the event that the input has no data that corresponds to the intended content of the table. Once the fixed set of tables is displayed, the process of displaying tables in a user interface page is completed.
Displaying a fixed set of tables for an input type to a web application is effective in enabling information associated with the input to be provided for viewing. In some instances, however, when a particular input of an input type has no associated information for a given table, displaying the table with no rows of data may be inefficient. Tables with substantially no content effectively occupy display space, and essentially do not provide any useful information. Occupying display space with tables that have substantially zero content may clutter up a display window, and confuse a viewer.
Therefore, what is needed is a method and an apparatus that prevents substantially empty tables from being displayed. That is, what is desired is a system that enables inputs of the same input type to potentially display different sets of tables.